﻿Imports System.ComponentModel

Public Class BillItems
    Implements INotifyPropertyChanged

    Private _ItemName As String = String.Empty

    Private _ItemID As Integer

    Private _Description As String = String.Empty

    Private _Qty As Integer = 1

    Private _UOMName As String = String.Empty

    Private _UOMID As Integer

    Private _Rate As Double

    Private _Amount As Double

    Public Property ItemName As String
        Get
            Return _ItemName
        End Get
        Set(ByVal value As String)
            _ItemName = value
            NotifyPropertyChanged()
        End Set
    End Property

    Public Property ItemID As Integer
        Get
            Return _ItemID
        End Get
        Set(ByVal value As Integer)
            _ItemID = value
            NotifyPropertyChanged()
        End Set
    End Property

    Public Property Description As String
        Get
            Return _Description
        End Get
        Set(ByVal value As String)
            _Description = value
            NotifyPropertyChanged()
        End Set
    End Property

    Public Property Qty As Integer
        Get
            Return _Qty
        End Get
        Set(ByVal value As Integer)
            _Qty = value
            NotifyPropertyChanged()
        End Set
    End Property

    Public Property UOMName As String
        Get
            Return _UOMName
        End Get
        Set(ByVal value As String)
            _UOMName = value
            NotifyPropertyChanged()
        End Set
    End Property

    Public Property UOMID As Integer
        Get
            Return _UOMID
        End Get
        Set(ByVal value As Integer)
            _UOMID = value
            NotifyPropertyChanged()
        End Set
    End Property

    Public Property Rate As Double
        Get
            Return _Rate
        End Get
        Set(ByVal value As Double)
            _Rate = value
            NotifyPropertyChanged()
        End Set
    End Property

    Public Property Amount As Double
        Get
            Return _Amount
        End Get
        Set(ByVal value As Double)
            _Amount = value
            NotifyPropertyChanged()
        End Set
    End Property

    Public Event PropertyChanged(ByVal sender As Object, ByVal e As System.ComponentModel.PropertyChangedEventArgs) Implements System.ComponentModel.INotifyPropertyChanged.PropertyChanged

    Private Sub NotifyPropertyChanged(Optional ByVal propertyName As String = Nothing)
        RaiseEvent PropertyChanged(Me, New PropertyChangedEventArgs(propertyName))
    End Sub
End Class